package com.knowvoyage.knowvoyageserver.mapper;

import com.knowvoyage.knowvoyageserver.pojo.entity.Question;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
@Mapper
public interface QuestionMapper {
    Integer countBySubject(Integer subject);
    Integer countByYear(Integer year);
    Integer countByType(Integer type);
    Integer countAll();
    // 条件筛选查询
    List<Question> selectByCondition(@Param("type") Integer type,
                                     @Param("subject") Integer subject,
                                     @Param("year") Integer year);
}
